@extends('admin::layouts.masterchat')
@section('content')
    <div class="sp_main d-flex flex-row h-100">
        <div class="sp_left col-3 p-0 m-0">
            <div class="sp_left_top" id="guest_div">访客 (<b class="online_guests">0</b>)</div>
            <div class="sp_left_mid scroll" id="g88"></div>
        </div>
        <div class="sp_center col-7 p-0 m-0">
            <div id="guest_history" class="guest_history scroll"></div>
            <div class="chatbox_bot">
                <div class="guest_tools">
                    <div class="tools_div">
                        <a class="t_smilies" title="表情符号" onclick="return false;"></a>
                        <a class="t_upload" title="图片或文件" onclick="doUpload();return false;"></a>
                        <a class="t_auth" title="授权访客上传文件" onclick="return false;"></a>
                        <a class="t_profile" title="记录访客信息" onclick="getProfile(this);return false;"></a>
                        <a class="t_microphone" title="麦克风" onclick="setMicrophone(this);return false;"></a>
                    </div>
                    <div class="clock inactive" id="welive_clock"><span>0:00:00</span></div>
                </div>
                <div class="guest_enter">
                    <div class="left"><textarea id="guest_msg" class="guest_msg scroll" placeholder="Ctrl + Enter: 发送"></textarea></div>
                    <div class="right btn" id="guest_send" onselectstart="return false;">发 送</div>
                    <div class="link-btn" id="send_mod_btn">^</div>
                    <div style="display:none;" id="send_mod_div">
                        <div onclick="setSendMod(0, this);" class="send_mod_0">Ctrl + Enter : 发送</div>
                        <div onclick="setSendMod(1, this);" class="send_mod_1">Enter : 发送</div>
                    </div>
                </div>
                <div class="copyright" id="welive_copyright"><div class="sysinfo">2021 © WeCaller 2.0.0 <a href="http://www.weensoft.cn/" target="_blank" onmouseover="sysinfo_tip(this);">为因软件 weensoft.cn</a> Done in 0.004 second(s), 2 queries, GMT+8 2021-03-30 15:27:02</div></div>
            </div>
            <div class="waver_container"><div class="voice_waver"><div class="wave"><div class="vw vw1"></div><div class="vw vw2"></div><div class="vw vw3"></div><div class="vw vw4"></div><div class="vw vw5"></div><div class="vw vw6"></div><div class="vw vw7"></div><div class="vw vw8"></div><div class="vw vw9"></div><div class="vw vw10"></div></div><div class="wave down"><div class="vw vw1"></div><div class="vw vw2"></div><div class="vw vw3"></div><div class="vw vw4"></div><div class="vw vw5"></div><div class="vw vw6"></div><div class="vw vw7"></div><div class="vw vw8"></div><div class="vw vw9"></div><div class="vw vw10"></div></div></div></div>
            <div id="guest_profile" class="g_profile" style="display:none;">
                <div class="t">访客信息</div>
                <form onsubmit="return false;">
                    <li>
                        <b>来源:</b><u><a href="" target="_blank" class="fromurl"></a></u>
                    </li>
                    <li><b>地区:</b><u class="ipzone"></u></li>
                    <li class="f">
                        <b>意向:</b>
                        <input type="radio" value="1" name="grade" id="g-g-1"><label for="g-g-1">1分</label>
                        <input type="radio" value="2" name="grade" id="g-g-2"><label for="g-g-2">2分</label>
                        <input type="radio" value="3" name="grade" id="g-g-3"><label for="g-g-3">3分</label>
                        <input type="radio" value="4" name="grade" id="g-g-4"><label for="g-g-4">4分</label>
                        <input type="radio" value="5" name="grade" id="g-g-5"><label for="g-g-5">5分</label>
                    </li>
                    <li><b>姓名:</b><input name="fullname" type="text" class="s"></li>
                    <li><b>备注:</b><textarea name="remark"></textarea></li>
                    <li class="bt">
                        <input class="cancel" type="submit" value="保存更新" onclick="saveGuest(this);return false;">&nbsp;&nbsp;&nbsp;&nbsp;
                        <input class="cancel" type="submit" value=" 取消 " onclick="return closeProfile();">
                    </li>
                </form>
            </div>
            <div id="video_container" onclick="toggleVideoSize(this);"><video id="remoteVideo" autoplay="" muted=""></video><div class="shut_btn" onclick="xGuestCamera();">X</div></div>
        </div>
        <div class="sp_right col-3 p-0 m-0">
            <ul class="sp_right_tab">
                <li class="toggle_btn curr" for="1">客服 (<b id="sp_num">0</b>)<b id="s_chat_num">0</b><span class="line"></span></li>
                <li class="toggle_btn" for="2">快捷回复<span class="line"></span></li>
            </ul>
            <div class="sp_right_div" id="div_for_btn1">
                <div class="sp_mid">
                    <div id="sp_history" class="scroll loading3">
                        <div id="sp_list" class="scroll"></div>
                </div>
                <div class="sp_face"></div>
                <div class="sp_bott">
                    <div class="left"><textarea id="sp_msg" placeholder="Ctrl + Enter: 发送" class="sp_msg scroll"></textarea></div>
                    <div class="right btn" id="sp_send" onselectstart="return false;">发 送</div>
                </div>
            </div>
            <div class="sp_right_div scroll" style="display:none;" id="div_for_btn2">
                <div class="sp_mid">
                    <div id="sp_phrases_cn" onselectstart="return false;" class="scroll"><div>暂未添加快捷回复</div></div>
                    <div id="sp_phrases_en" onselectstart="return false;" style="display:none;" class="scroll"><div>No common phrases added</div></div>
                </div>
                <div class="sp_bott">
                    <div class="left"><textarea id="sp_phrase_msg" placeholder="添加快捷回复" class="sp_msg scroll"></textarea></div>
                    <div class="right btn" onselectstart="return false;" onclick="addPhrase();">添 加</div>
                </div>
            </div>
        </div>
    </div>

@endsection
@section('scripts')
    <script>
        function del(id, el) {
            if (confirm('确定删除吗？')) {
                $(el).next('form').trigger('submit')
            }
        }
    </script>
@endsection
